package com.cltech.service.sys.impl;

import com.cltech.entity.sys.SysOperationLog;
import com.cltech.frame.base.impl.BaseServiceImpl;
import com.cltech.repository.sys.SysOperationLogRepository;
import com.cltech.service.sys.SysOperationLogService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;

/**
 * Created by Administrator on 2019/3/18.
 */
@Service("sysOperationLogService")
public class SysOperationLogServiceImpl extends BaseServiceImpl<SysOperationLog, String> implements SysOperationLogService {
    private SysOperationLogRepository sysOperationLogRepository;
    @Autowired
    public void setSysUserRepository(SysOperationLogRepository sysOperationLogRepository) {
        this.sysOperationLogRepository = sysOperationLogRepository;
        super.setBaseRepository(sysOperationLogRepository);
    }

    @Async("logExecutor")
    @Override
    public void asyncSave(SysOperationLog sysOperationLog) {
        save(sysOperationLog);
    }
}
